import pytest,unittest
from report_829 import Tools
import sys
import os
# 获取当前文件所在目录的父目录路径
parent_dir = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
# 将父目录加入系统路径
sys.path.append(parent_dir)

if __name__ == '__main__':
    # suite=unittest.defaultTestLoader.discover(start_dir='D:/gao1/PythonProject4/report_829/',pattern='plwrightpy126.py')
    # Tools.report().run(suite)



    # pytest执行生成html报告
    pytest.main([r'D:\gao1\PythonProject4\report_829\plwrightpy126.py','-s','--html=126.html'])

